package com.gitee.lirns.basement.entity.result;

/**
 * 枚举
 * @author liruilin
 * @date 2021/1/27 15:00
 */
public enum ResultCode {
    //成功
    SUCCESS(1000, "操作成功"),
    //失败
    FAILED(1001, "响应失败"),
    //参数校验失败
    VALIDATE_FAILED(1002, "参数校验失败"),
    //未知错误
    ERROR(5000, "未知错误");

    private Integer code;
    private String message;

    ResultCode(Integer code, String message) {
        this.code = code;
        this.message = message;
    }

    public Integer getCode() {
        return code;
    }

    public String getMessage() {
        return message;
    }
}
